<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>拓展运算符</title>
</head>
<body>
    <script>
        // function foo(a,b,c){
        //     console.log(a+b+c);
        // }

        // let nums =[5,6,7]
        // foo(...nums);

        let nums1 =[1,2,3];
        let nums2 =[4,5,6];
        let all =[...nums1,...nums2]
        console.log(all);

        let arr = [8,7,5,4,...nums2];
        console.log(arr);
         
    </script>
</body>
</html>